<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>Title</title>
</head>
<body>

<script>
    Promise.all([
        // new Promise((resolve, reject) => {
        //     $.ajax({
        //         url: 'url1',
        //         success: data => {
        //             resolve(data)
        //         }
        //     })
        // }),
        // new Promise((resolve, reject) => {
        //     $.ajax({
        //         url: 'url2',
        //         success: data => {
        //             resolve(data)
        //         }
        //     })
        // })

        new Promise((resolve, reject) => {
            setTimeout(() => {
                resolve('result1')
            }, 4000)
        }),
        new Promise((resolve, reject) => {
            setTimeout(() => {
                resolve('result2')
            }, 4000)
        })
    ]).then(results => {
        console.log(results);
    })
</script>

</body>
</html>